package com.cc.web.vo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.cc.infrastructure.special.dto.AmountDo;
import com.cc.infrastructure.db.AmountDb;


@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel("前端传递参数")
public class AmountVo {

  /**
   *
   **/
  @ApiModelProperty("")
  private String id;
  /**
   *
   **/
  @ApiModelProperty("")
  private String supplyId;
  /**
   *
   **/
  @ApiModelProperty("")
  private String moneyType;
  /**
   *
   **/
  @ApiModelProperty("")
  private String amount;

  public static AmountVo convertAmountVoByAmountDo(AmountDo amountDo) {
    AmountVo amountvo = new AmountVo();
    amountvo.setId(amountDo.getId());
    amountvo.setSupplyId(amountDo.getSupplyId());
    amountvo.setMoneyType(amountDo.getMoneyType());
    amountvo.setAmount(amountDo.getAmount());
    return amountvo;
  }

  public static AmountVo convertAmountVoByAmountDo(AmountDb amountDb) {
    AmountVo amountvo = new AmountVo();
    amountvo.setId(amountDb.getId());
    amountvo.setSupplyId(amountDb.getSupplyId());
    amountvo.setMoneyType(amountDb.getMoneyType());
    amountvo.setAmount(amountDb.getAmount());
    return amountvo;
  }
}